home *** CD-ROM | disk | FTP | other *** search
/ Sprite 1984 - 1993 / Sprite 1984 - 1993.iso / src / cmds / gdb.new / gdb-3.98 / gdb / configure.in < prev    next >
Encoding:
Text File  |  1991-08-01  |  1.4 KB  |  60 lines

  1. srcname="GDB"
  2. srctrigger=main.c
  3.  
  4. # per-host:
  5.  
  6. if [ ! -f xconfig/${host} ]; then
  7.     echo "No such host ${host}"
  8.     exit 1
  9. fi
  10.  
  11. #  We really shouldn't depend on there being a space after XM_FILE= ...
  12. hostfile=`awk '$1 == "XM_FILE=" { print $2 }' <xconfig/$host`
  13.  
  14. # per-target:
  15.  
  16. if [ ! -f tconfig/${target} ]; then
  17.     echo "No such target ${target}"
  18.     exit 1
  19. fi
  20.  
  21. if [ -z "${removing}" ] ; then
  22.     cat xconfig/${host} tconfig/${target} | awk '$1 == "#msg" {
  23.         print substr($0,6)}'
  24. fi
  25.  
  26. #  We really shouldn't depend on there being a space after TM_FILE= ...
  27. targetfile=`awk '$1 == "TM_FILE=" { print $2 }' <tconfig/$target`
  28.  
  29. host_makefile_frag=xconfig/${host}
  30. target_makefile_frag=tconfig/${target}
  31.  
  32. # If hostfile (XM_FILE) and/or targetfile (TM_FILE) is not set in the
  33. # ?config/* file, we don't make the corresponding links.  But we have
  34. # to remove the xm.h files and tm.h files anyway, e.g. when switching
  35. # from "configure host" to "configure none".
  36. files=
  37. links=
  38. rm -f xm.h
  39. if [ "${hostfile}" != "" ]; then
  40.     files="${files} ${hostfile}"
  41.     links="${links} xm.h"
  42. fi
  43. rm -f tm.h
  44. if [ "${targetfile}" != "" ]; then
  45.     files="${files} ${targetfile}"
  46.     links="${links} tm.h"
  47. fi
  48.  
  49. # post-target:
  50.  
  51. case ${srcdir} in
  52.   .)
  53.     ;;
  54.   *)
  55.     grep -s "source ${srcdir}/.gdbinit" .gdbinit 2>/dev/null || \
  56.       echo "source ${srcdir}/.gdbinit" >> .gdbinit
  57. esac
  58.  
  59. cat ${srcdir}/alldeps.mak ${srcdir}/depend >>Makefile
  60.